<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>

<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 
<title>Book Store</title>
<link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath }/style/style.css" />

<script>
	function detailsBook(id){
		window.location = '${path }/book/detail?id='+id;
	}
</script>

</head>
<body>
<div id="wrap">
  <!-- 导航栏加头 -->
  <%-- <%@ include file="../common/header.jsp" %> --%>
  <jsp:include page="../common/header.jsp">
  	<jsp:param value="index" name="css"/>
  </jsp:include>
  <!-- 导航栏加头 -->
       
  <!-- 中心内容 -->     
  <div class="center_content">
  	  <!-- 中间左边的内容 -->
      <div class="left_content">
      	 <!-- 精选图书 -->
         <div class="title"><span class="title_icon"><img src="${path}/images/bullet1.gif" alt="" title="" /></span>精选图书</div>
         <!-- 一本精选图书 -->
         <c:forEach var="book" items="${bestBook.datas }">
         	<div>
	             <div class="feat_prod_box">
	                 <div class="prod_img"><a href="javascript:void(0)" onclick="detailsBook('${book.id }')"><img style='width:98px;height:150px' src="${pageContext.request.contextPath }/images/book_img/${book.imgUrl }" alt="" title="" border="0" /></a></div>
	                    <div class="prod_det_box">
	                        <div class="box_top"></div>
	                        <div class="box_center">
	                            <div class="prod_title">图书名称:&nbsp;&nbsp;${book.bookName }</div>
	                            <p class="details">作&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;者：${book.author }</p>
	                            <p class="details">出&nbsp;&nbsp;版&nbsp;&nbsp;社：人民出版社</p>
	                            <p class="details">出版日期：2001-01-01</p>
	                            <p class="details">价&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;格：${book.price }元</p>
	                            <a href="javascript:void(0)" onclick="detailsBook('${book.id }')" class="more">- 更多信息 -</a>
	                            <div class="clear"></div>
	                        </div>
	                        
	                        <div class="box_bottom"></div>
	                    </div>    
	                <div class="clear"></div>
	            </div>	
	         </div>	
         </c:forEach>
         
         <!-- 一本精选图书结束 -->
         
         
            <!-- 新书 -->
           <div class="title"><span class="title_icon"><img src="${path}/images/bullet2.gif" alt="" title="" /></span>新书</div> 
           
           <div class="new_products">
           		<c:forEach var="nbook" items="${newBook.datas }">
	                <div class="new_prod_box">
	                    <a href="javascript:void(0)" onclick="detailsBook('${nbook.id}')">${nbook.bookName }</a>
	                    <div class="new_prod_bg">
	                    <span class="new_icon"><img src="${path }/images/new_icon.gif"  alt="" title="" /></span>
	                    <a href="javascript:void(0)" onclick="detailsBook('${nbook.id}')"><img src="${path }/images/book_img/${nbook.imgUrl }" style="width:60px;height:90px" alt="" title="" class="thumb" border="0" /></a>
	                    </div>           
	                </div>
                </c:forEach>
            </div> 
        <div class="clear"></div>
    </div>
    <!--end of left content-->
     
    	<!-- 右边内容开始 -->   
    	<%@ include file="../common/aside.jsp" %>
    	<!--end of right content-->
       <div class="clear"></div>
  </div>
  <!--end of center content-->
  
  <!-- 网站尾部 -->            
  <%@ include file="../common/foot.jsp" %>
  <!-- 网站尾部 -->   

</div>

</body>
</html>